package service.Impl;

import dao.Impl.PetDaoImpl;
import dao.PetDao;
import entity.Pet;
import service.PetService;

import java.util.List;

public class PetServiceImpl implements PetService {
    private PetDao petDao = new PetDaoImpl();
    @Override
    public List<Pet> findAll() {
        return petDao.findAll();
    }

    @Override
    public List<Pet> findPetByName(String petName) {
        return petDao.findPetByName(petName);
    }

    @Override
    public Pet findPetById(int id) {
        return petDao.findPetById(id);
    }

    @Override
    public void addPet(Pet pet) {
        petDao.addPet(pet);
    }

    @Override
    public void updatePet(Pet pet) {
        petDao.updatePet(pet);
    }

    @Override
    public boolean deletePet(int id) {
        petDao.deletePet(id);
        return false;
    }

    @Override
    public List<Pet> findNoPet() {
        return petDao.findNoPet();
    }

    @Override
    public List<Pet> findPetByNoState() {
        return petDao.findPetByNoState();
    }


}
